#include <iostream>
#include <string>
#include "selectServer.hpp"
// using namespace std;
void Usage(std::string name)
{
    std::cout<<"Usage: "<<name<<"port"<<std::endl;
    exit(-1);
}
int main(int argc,char* argv[])
{
    //1. test how much bit do fd_set have,we use sizeof(fd_set)*8;
    // std::cout<<sizeof(fd_set)*8<<std::endl;
    if(argc!=2)Usage(argv[0]);

    uint16_t port;
    port=atoi(argv[1]);
    unique_ptr<SelectServer> ptr(new SelectServer(port));//只有构造函数，没有赋值和拷贝构造函数
    ptr->Start();
    
    return 0;
}